home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / automa_1 / frmabout.frm (.txt) < prev    next >
Visual Basic Form  |  1999-08-23  |  5KB  |  157 lines

  1. VERSION 5.00
  2. Begin VB.Form frmAbout 
  3.    BorderStyle     =   4  'Fixed ToolWindow
  4.    Caption         =   "About Phr
  5. stByte"
  6.    ClientHeight    =   2985
  7.    ClientLeft      =   45
  8.    ClientTop       =   285
  9.    ClientWidth     =   5985
  10.    ForeColor       =   &H000000FF&
  11.    LinkTopic       =   "Form1"
  12.    MaxButton       =   0   'False
  13.    MinButton       =   0   'False
  14.    Picture         =   "frmAbout.frx":0000
  15.    ScaleHeight     =   2985
  16.    ScaleWidth      =   5985
  17.    ShowInTaskbar   =   0   'False
  18.    StartUpPosition =   2  'CenterScreen
  19.    Begin VB.Timer Timer1 
  20.       Interval        =   1
  21.       Left            =   0
  22.       Top             =   1320
  23.    End
  24.    Begin VB.PictureBox Picture2 
  25.       BackColor       =   &H0000FFFF&
  26.       BorderStyle     =   0  'None
  27.       Height          =   1395
  28.       Left            =   240
  29.       ScaleHeight     =   1395
  30.       ScaleWidth      =   5475
  31.       TabIndex        =   0
  32.       Top             =   1440
  33.       Width           =   5475
  34.       Begin VB.PictureBox P1 
  35.          BorderStyle     =   0  'None
  36.          BeginProperty Font 
  37.             Name            =   "Verdana"
  38.             Size            =   14.25
  39.             Charset         =   0
  40.             Weight          =   700
  41.             Underline       =   0   'False
  42.             Italic          =   0   'False
  43.             Strikethrough   =   0   'False
  44.          EndProperty
  45.          Height          =   2805
  46.          Left            =   0
  47.          Picture         =   "frmAbout.frx":6B1F
  48.          ScaleHeight     =   2805
  49.          ScaleWidth      =   5535
  50.          TabIndex        =   1
  51.          Top             =   720
  52.          Width           =   5535
  53.       End
  54.    End
  55.    Begin VB.Label Label1 
  56.       BackStyle       =   0  'Transparent
  57.       Height          =   975
  58.       Left            =   240
  59.       MouseIcon       =   "frmAbout.frx":DE54
  60.       MousePointer    =   99  'Custom
  61.       TabIndex        =   2
  62.       Top             =   240
  63.       Width           =   5415
  64.    End
  65. Attribute VB_Name = "frmABout"
  66. Attribute VB_GlobalNameSpace = False
  67. Attribute VB_Creatable = False
  68. Attribute VB_PredeclaredId = True
  69. Attribute VB_Exposed = False
  70. Dim thetop As Long
  71. Dim p1hgt As Long
  72. Dim p1wid As Long
  73. Dim theleft As Long
  74. Dim Tempstring As String
  75. Dim pth As String
  76. Private Sub Command1_Click()
  77. 'ShowCursor False
  78.   Dim MyValue As Byte, x
  79.   Randomize
  80. Status = "Stars"
  81.     Do While ActionMode = "Running"
  82.       Background = LoadPicture ' clear the background
  83.       For i = 0 To StarCount
  84.        
  85.         SetPixel Background.hdc, Star(i).StarX, Star(i).StarY + Star(i).SpeedY, QBColor(Star(i).StarColor)
  86.       Next i
  87.       Background.Refresh
  88.       DoEvents
  89.     Loop
  90.     DoEvents
  91. Status = "Stars"
  92.   StarSetup Picture2.Height, Picture2.Width
  93. End Sub
  94. Private Sub Form_Activate()
  95. StarSetup P1.Height, P1.Width
  96. End Sub
  97. Private Sub Form_Click()
  98. Unload Me
  99. End Sub
  100. Sub Form_Load()
  101. pth = App.Path & "/Graphics/"
  102.         P1.AutoRedraw = True
  103.         P1.Visible = False
  104.         P1.FontSize = 12
  105.         P1.ForeColor = &H0&
  106.         P1.BackColor = Picture2.BackColor
  107.         P1.ScaleMode = 3
  108.         Picture2.ScaleMode = 3
  109.         Open (App.Path & "\about.txt") For Input As #1
  110.         Line Input #1, Tempstring
  111.         P1.Height = (Val(Tempstring) * P1.TextHeight("Test Height")) + 200
  112.         Do Until EOF(1)
  113.             Line Input #1, Tempstring
  114.             PrintText Tempstring
  115.         Loop
  116.         Close #1
  117.         theleft = 0
  118.         thetop = Picture2.ScaleHeight
  119.         p1hgt = P1.ScaleHeight
  120.         p1wid = P1.ScaleWidth
  121.         Timer1.Enabled = True
  122.         Timer1.Interval = 10
  123. End Sub
  124. Private Sub PicBack_Click()
  125. End Sub
  126. Private Sub Picture1_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single)
  127. FormDrag Me
  128. End Sub
  129. Private Sub Label1_Click()
  130. frmWeb.Show
  131. frmWeb.WebBrowser1.Navigate "http://www.vbtutor.com"
  132. End Sub
  133. Sub Timer1_Timer()
  134. On Error Resume Next
  135. Dim x%, txt$
  136.        x% = BitBlt(Picture2.hdc, theleft, thetop, p1wid, p1hgt, P1.hdc, 0, 0, &HCC0020)
  137.         thetop = thetop - 1
  138.         If thetop < -p1hgt Then
  139.         Timer1.Enabled = False
  140.         txt$ = "Credits Completed"
  141.         CurrentY = ScaleHeight / 2
  142.         CurrentX = (ScaleWidth - TextWidth(txt$)) / 2
  143.         Print txt$
  144.         End If
  145. If Err Then MsgBox Err.Description, vbOKOnly + vbCritical, "Error #" & Err.Number
  146. End Sub
  147. Sub PrintText(Text As String)
  148. Dim x, y, i
  149. P1.ForeColor = &H0&: x = P1.CurrentX: y = P1.CurrentY
  150. For i = 1 To 3
  151.     P1.Print Text
  152.     x = x + 1: y = y + 1: P1.CurrentX = x: P1.CurrentY = y
  153. Next i
  154. P1.ForeColor = &HFF&
  155. P1.Print Text
  156. End Sub
  157.